﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Backend.JYD.Model;
using Backend.JYD.Model.Auth;
using Backend.JYD.IDAL.Auth;

namespace Backend.JYD.BLL
{
    public class MenuInfoBLL
    {
        private static readonly IMenuInfo idal = Factory.DALFactory.CreateEFDAL<IMenuInfo>("DAL.MenuInfoDAL");

        public MenuInfo GetMenuInfoById(string menuId)
        {
            return idal.GetMenuInfoById(menuId);
        }
        /// <summary>
        /// isAll = false 过滤不可用用户
        /// </summary>
        public List<MenuInfo> GetMenuInfoByMenuIds(List<string> menuIds)
        {
            if (menuIds == null || menuIds.Count <= 0) return null;
            var temp = idal.GetMenuInfoByIds(menuIds);
            return temp == null ? null : temp.ToList();
        }
    }
}
